package com.thientan.service

import com.thientan.export.ExportRequest

class ThongKeGiaoPhieuThuService extends AbstractService {
	@Override
	protected Long[] getColWidth() {
		return [80, 80, 80, 60, 100] as Long[]
	}

	@Override
	protected String[] getColTitles() {
		return [
			"Mã hợp đồng",
			"Mã thu ngân",
			"Tên thu ngân",
			"Số phiếu",
			"Số tiền phải thu"] as String[]
	}

	@Override
	protected String[] getColNames() {
		return [
			"maHd",
			"maTn",
			"tenTn",
			"soPhieu",
			"soTien"] as String[]
	}

	@Override
	@SuppressWarnings("rawtypes")
	protected Class<?>[] getExportColType() {
		return [
			String.class,
			String.class,
			String.class,
			BigDecimal.class,
			BigDecimal.class] as Class<?>[]
	}

	@Override
	void prepareParametersBeforeExport(ExportRequest er){
		er.addParameter("ngayXuat", this.exportData?.ngayXuat)
		er.addParameter("thoiGian", this.exportData?.thoiGian)
		er.addParameter("tongPhieu", this.exportData?.tongPhieu)
		er.addParameter("tongTien", this.exportData?.tongTien)
	}
}
